<?php

$data = array('msg' => null, 'type' => 'location','table' => 'locations');

$data['search_fields'] = array(
  'location',
  'spot',
  'department',
  'floor',
  'building',
);

$data['list_fields'] = array(
  'department_id',
);

$data['joins'] = array(
  'departments',
  'buildings'
);

$data['join_fields'] = array(
  '`department_id`=`departments`.`id`',
  '`building_id`=`buildings`.`id`'
);

$data['alias'] = array(
  '*, locations.id',
  'CONCAT(spot,\' -  \',location) AS location_spot'
);

$data['order'] = 'building, department, floor, spot, location';

?>
